let axios = require('axios');
module.exports ={
    namespaced:true,
    state: {
        goodstypes:[],
        current:"",
        pageSize:"",
        total:"",
        
    },
    mutations: {
        getTypes(state,data){
            console.log(data);
            
            state.goodstypes=data
        },
        
    },
    actions: {
        async getTypesAsync(context){
            let data = await axios.get('/types/getAll');
            context.commit('getTypes', data.data);
        }

    },
    modules: {
    }
}